visibility
XBasic language elements are identifiable by visual inspection. KEYWORDS are descriptively
named and fully capitalized. Functions() are always followed by parentheses, whether
they take arguments or not. Arrays[] are always followed by square brackets.
Standardized suffixes can be used to make data type evident. Composite levels are
separated by dots, as in employee.name. Constants local to a function have a $
prefix, like $YES and $NO, while shared constants have a $$ prefix, like $$ROWS and
$$COLUMNS. # and ## prefixes explicitly and visibly mark SHARED and EXTERNAL
variables.
Visibility makes XBasic programs easy to read and understand. The kind of object
every symbol represents is evident, as well as its scope and data type where applicable.
When programmers use variable names that are as concise and descriptive as XBasic
keywords, the kind, type, meaning, and use of virtually every element is immediately
evident. There is no need to attempt to hold dozens or hundreds of symbols in mind,
along with mental notes to check what these symbols represent.
portability
Portable programs work properly on computers of different model, manufacturer, or
architecture. An ideal portable program can be taken from system to system and run
without complication. This ideal is rarely achieved. Several difficulties can
arise, most commonly from compiler and language variations. Even compilers that
specify identical, standardized source syntax can present serious obstacles due to the
nature of "standards" like ANSI standard C. So the language can run on
virtually any computer, many features are "implementation dependent" (which
means "not standard"). This means that different compilers, even on the
same computer, can produce very different results and still comply with the so-called
"standard".
XBasic is far more restrictive with regard to implementation dependencies. By
limiting itself to modern 32-bit and 64-bit architectures, XBasic avoids the need for
implementation dependence. XBasic considers portability a crucial feature of modern
programming languages.
XBasic provides system independent graphics and GUI functionality. XBasic programs
with graphics and GUIs are therefore portable from computer to computer, even when they
have different CPUs, operating systems, and underlying graphics and window systems.
system programming
While QB and VB are incapable of serious system programming, XBasic is well suited. XBasic
expands some of the good ideas from C, and adds new ones of its own. But XBasic is
not cryptic like C, yet it's often faster. By providing high-level alternatives to
addresses, pointers, and indirection, XBasic programs, especially system programs, are
clearer, more portable, and more reliable. Furthermore, memory allocation is
implemented in a new way that is faster than C. Though XBasic memory allocation
functions are not implemented as in C, they are upward compatible. So C functions
can call them, often with significant speed improvement.
data types
XBasic supports a complete set of built-in data types, including signed and unsigned
integer types from 8-bits to 64-bits, single and double precision floating point types,
single and double precision complex types, and character strings. XBasic also
supports user-defined structures, and arrays of all data types.